﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="YinHangPLDLYW.aspx.cs" Inherits="Web.Pages.YongShui.YinHangPLDLYW" Theme="Default" %>

<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.9.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dx" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title></title>
    <script src="../../../../JS/AddEditCancel.js"></script>
    <script type="text/javascript">
        function selectedGuanlikChange() {
            //cmbconGuanlik.PerformCallback();
        }
        //打开托收情况汇总
        function openGeneranize() {
            openCenter("/Pages/YongShui/5.ShouFeiGL/ZhiPiaoXJFW_CK.aspx?ym=" + encodeURI(tab2txtZWYM.GetText()), "600px", "450px");
        }
        function QuXiaoWJ() {
            if (confirm("是否确认取消文件！？")) {
                btnCancelFile.OnClick();
            }
        }

        function DowanLoadFile(id, wenjianmc) {
            var url = "/ashx/YSSF/YinHangDLDC.ashx?i_id=" + id + "&wenjianm=" + wenjianmc;
            window.open(url);
        }
    </script>
</head>
<body>
    <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
        <div class="tabletitle1" align="center">
            银行批量代理业务
        </div>
        <asp:UpdatePanel ID="updatePanel1" runat="server">
            <%--   <Triggers>
                <asp:PostBackTrigger ControlID="ASPxPageControl1" />
            </Triggers>--%>
            <ContentTemplate>
                <dx:ASPxPageControl ID="ASPxPageControl1" runat="server" ActiveTabIndex="0" Width="100%" Height="520px">
                    <TabPages>
                        <dx:TabPage Text="付款人合同号">
                            <ContentCollection>
                                <dx:ContentControl>
                                    <table>
                                        <tr>
                                            <td style="">水量年月：</td>
                                            <td>
                                                <dx:ASPxTextBox ID="txtconYM" runat="server" Width="80px">
                                                    <ClientSideEvents KeyUp="function(s,e){inputNum(s);if(event.keyCode==13){btnconSearch.onClick();}}" />
                                                </dx:ASPxTextBox>
                                            </td>
                                            <td>
                                                <dx:ASPxButton ID="btnconSearch" ClientInstanceName="btnconSearch" runat="server" Text="查询" UseSubmitBehavior="false" OnClick="btnconSearch_Click"></dx:ASPxButton>
                                            </td>
                                            <td>
                                                <dx:ASPxButton ID="btnExportExcel" runat="server" Text="导出excel" UseSubmitBehavior="false" OnClick="btnExport_Click">
                                                    <%--<ClientSideEvents Click="function(s,e){btnExport.OnClick();}" />--%>
                                                </dx:ASPxButton>
                                            </td>
                                        </tr>
                                    </table>
                                    <dx:ASPxGridView ID="gvFUKUANRHTH" runat="server" AutoGenerateColumns="False" KeyFieldName="S_YONGHUH" Theme="Aqua1" Width="100%">
                                        <Columns>
                                            <dx:GridViewDataTextColumn FieldName="S_YONGHUH" Caption="用户号" Width="10%">
                                            </dx:GridViewDataTextColumn>
                                            <dx:GridViewDataTextColumn FieldName="S_ZHANGHAO" Caption="账号" Width="20%">
                                            </dx:GridViewDataTextColumn>
                                            <dx:GridViewDataTextColumn FieldName="S_HUMING" Caption="户名" Width="20%">
                                            </dx:GridViewDataTextColumn>
                                            <dx:GridViewDataTextColumn FieldName="S_KAIHUH" Caption="开户行" Width="20%">
                                            </dx:GridViewDataTextColumn>
                                            <dx:GridViewDataTextColumn FieldName="S_HETONGH" Caption="合同号" Width="30%">
                                            </dx:GridViewDataTextColumn>
                                        </Columns>
                                        <Settings VerticalScrollableHeight="380" VerticalScrollBarMode="Auto" HorizontalScrollBarMode="Auto" />
                                    </dx:ASPxGridView>
                                    <div style="height: 3px;"></div>
                                    <div>
                                        <span style="float: left;">
                                            <dx:ASPxLabel ID="lblRecordCount" runat="server" Text="共有2条记录"></dx:ASPxLabel>
                                        </span><span style="float: right;">
                                            <table>
                                                <tr>
                                                    <td>
                                                        <dx:ASPxButton ID="ASPxButton2" runat="server" Text="导入地下水数据" UseSubmitBehavior="false" Visible="false"></dx:ASPxButton>
                                                    </td>
                                                    <td>
                                                        <dx:ASPxButton ID="ASPxButton3" runat="server" Text="导入水资源数据" UseSubmitBehavior="false" Visible="false"></dx:ASPxButton>
                                                    </td>
                                                    <td>
                                                        
                                                    </td>
                                                </tr>
                                            </table>
                                    </div>
                                </dx:ContentControl>
                            </ContentCollection>
                        </dx:TabPage>
                        <dx:TabPage Text="上传银行文件">
                            <ContentCollection>
                                <dx:ContentControl>
                                    <div>
                                        <div style="width: 45%; float: left;">
                                            <fieldset style="border: 1px solid  cornflowerblue">
                                                <legend style="font-weight: bold">数据</legend>
                                                <dx:ASPxGridView ID="gvYINHANGPLDLHTL1" runat="server" AutoGenerateColumns="False" KeyFieldName="S_WENJIANM" Theme="Aqua1" Width="100%">
                                                    <Columns>
                                                        <dx:GridViewDataTextColumn FieldName="S_WENJIANM" Caption="文件名" Width="50%">
                                                        </dx:GridViewDataTextColumn>
                                                        <dx:GridViewDataTextColumn FieldName="N_ZONGJINE" Caption="总金额" Width="25%">
                                                        </dx:GridViewDataTextColumn>
                                                        <dx:GridViewDataTextColumn FieldName="I_ZONGBIS" Caption="总笔数" Width="25%">
                                                        </dx:GridViewDataTextColumn>
                                                    </Columns>
                                                    <Settings VerticalScrollableHeight="380" VerticalScrollBarMode="Auto" />
                                                </dx:ASPxGridView>
                                            </fieldset>
                                        </div>
                                        <div style="width: 1%; float: left;">&nbsp;</div>
                                        <div style="width: 54%; float: left;">
                                            <fieldset style="border: 1px solid  cornflowerblue">
                                                <legend style="font-weight: bold">文件</legend>
                                                <dx:ASPxGridView ID="gvYINHANGPLDLHTL2" runat="server" AutoGenerateColumns="False" KeyFieldName="S_WENJIANM" Theme="Aqua1" Width="100%">
                                                    <Columns>
                                                        <dx:GridViewDataTextColumn FieldName="S_WENJIANM" Caption="文件名" Width="30%">
                                                        </dx:GridViewDataTextColumn>
                                                        <dx:GridViewDataTextColumn FieldName="N_ZONGJINE" Caption="总金额" Width="20%">
                                                        </dx:GridViewDataTextColumn>
                                                        <dx:GridViewDataTextColumn FieldName="I_ZONGBIS" Caption="总笔数" Width="20%">
                                                        </dx:GridViewDataTextColumn>
                                                        <dx:GridViewDataTextColumn FieldName="D_SHANGCHUANRQ" Caption="上传日期" Width="20%" PropertiesTextEdit-DisplayFormatString="yyyy-MM-dd">
                                                        </dx:GridViewDataTextColumn>
                                                        <dx:GridViewDataTextColumn MinWidth="85" Width="8%" Caption="操作">
                                                            <DataItemTemplate>
                                                                <a href="javascript:DowanLoadFile(<%#Eval("I_ID")%>, '<%#Eval("S_WENJIANM") %>.txt')">提取</a>
                                                            </DataItemTemplate>
                                                        </dx:GridViewDataTextColumn>
                                                    </Columns>
                                                    <Settings VerticalScrollableHeight="380" VerticalScrollBarMode="Auto" />
                                                </dx:ASPxGridView>
                                            </fieldset>
                                        </div>
                                    </div>
                                    <div style="margin-top: 4px;">
                                        <table align="right">
                                            <tr>
                                                 <td>
                                                    <dx:ASPxButton ID="btnRefresh" runat="server" Text="刷新" UseSubmitBehavior="false"  OnClick="btnRefresh_Click"></dx:ASPxButton>
                                                </td>
                                                <td>
                                                    <dx:ASPxButton ID="btnCreateFile" runat="server" Text="生成文件" UseSubmitBehavior="false" OnClick="btnCreateFile_Click" OnInit="btnCreateFile_Init" >
                                                       
                                                    </dx:ASPxButton>
                                                </td>
                                                <td>
                                                    <dx:ASPxButton ID="ASPxButton1" runat="server" Text="取消文件" UseSubmitBehavior="false" AutoPostBack="false">
                                                        <ClientSideEvents Click="function(s,e){QuXiaoWJ();}" />
                                                    </dx:ASPxButton>
                                                    <span style="display: none">
                                                        <dx:ASPxButton ID="btnCancelFile" ClientInstanceName="btnCancelFile" runat="server" Text="取消文件" UseSubmitBehavior="false" OnClick="btnCancelFile_Click"></dx:ASPxButton>
                                                    </span>
                                                </td>
                                            </tr>
                                        </table>
                                    </div>
                                </dx:ContentControl>
                            </ContentCollection>
                        </dx:TabPage>
                    </TabPages>
                </dx:ASPxPageControl>
            </ContentTemplate>
        </asp:UpdatePanel>
       
        <%-- <div style="display:none;">
            <dx:ASPxGridViewExporter ID="ASPxGridViewExporter1" runat="server"></dx:ASPxGridViewExporter>
            <dx:ASPxButton ID="btnExport" runat="server" ClientInstanceName="btnExport" Text="导出EXCEL" OnClick="btnExport_Click" UseSubmitBehavior="false">
            </dx:ASPxButton>
        </div> --%>  
    </form>
</body>
</html>


